package org.hongzhisoft.dis.service.impl;

import java.util.List;

import org.hongzhisoft.dis.bean.Role;
import org.hongzhisoft.dis.dao.RoleDao;
import org.hongzhisoft.dis.service.RoleService;

/**
 * 角色业务处理实现类
 * 
 * @author HongChengzhi
 *
 */
public class RoleServiceImpl implements RoleService {

	private RoleDao roleDao = new RoleDao();

	@Override
	public List<Role> selectByAll() throws Exception {
		return roleDao.selectAll();
	}

	@Override
	public Role selectById(int id) throws Exception {
		return roleDao.selectById(id);
	}

	@Override
	public int saveRole(Role Role) throws Exception {
		return roleDao.insertRole(Role);
	}

	@Override
	public int updateRole(Role Role) throws Exception {
		return roleDao.updateRole(Role);
	}

	@Override
	public int deleteRole(int id) throws Exception {
		return roleDao.deleteRole(id);
	}
	
	@Override
	public int statusChangeRole(int status, int id) throws Exception {
		return roleDao.statusChangeRole(status, id);
	}


}
